import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:sports_new/resources/colours.dart';
import 'package:sports_new/resources/styles.dart';
import 'package:sports_new/view/my/help/help_html.dart';
import '../../../entity/my/help/help_entity.dart';
import '../../../widgets/base/qkd_text.dart';

class HelpDetailPage extends StatefulWidget {
  const HelpDetailPage({super.key});

  @override
  State<HelpDetailPage> createState() => _HelpDetailPageState();
}

class _HelpDetailPageState extends State<HelpDetailPage> {
  QuestionEntity? entity = Get.arguments;

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: Styles.appBar(title: QkdText("问题详情")),
      body: SingleChildScrollView(
        child: Column(
          crossAxisAlignment: CrossAxisAlignment.start,
          children: [
            Container(height: 16),
            QkdText(entity?.title ?? "",
              fontSize: 18,
              fontWeight: FontWeight.w500
            ).paddingSymmetric(horizontal: 16),
            HelpHtml(content: entity?.content ?? "")
          ],
        ),
      ),
    );
  }
}
